<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ page import="com.chixing.pojo.CompanyAndJobs" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" isELIgnored="false" %>
<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>LinkedChat招聘网</title>
    <link rel="stylesheet" href="${pageContext.request.contextPath}/public/static/css/companyDetails.css">
    <link rel="stylesheet" type="text/css" href="${pageContext.request.contextPath}/public/static/css/Headers.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/public/static/css/Footers.css">
    <link rel="stylesheet" href="${pageContext.request.contextPath}/public/static/layui/css/layui.css">
    <link href="${pageContext.request.contextPath}/public/static/images/login_icon.ico" rel="shortcut icon">
    <script src="${pageContext.request.contextPath}/public/static/js/jquery-3.6.0.min.js"></script>
    <script type="text/javascript" src="https://api.map.baidu.com/api?v=3.0&ak=8muMyrLMQemAfxZAi9U2D5gUwW1hIB8t"></script>
</head>
<body>
<!--头部-->
<div id="header">
</div>
<script>
    $(function() {
        $('#header').load('${pageContext.request.contextPath}/public/Person/header.jsp');
    })
</script>


<!--主体-->
<div class="company-banner" style="">
    <div class="inner home-inner">
        <div>
            <div class="company-stat">
                <span><a href="#" ka="all-jobs-top"><b>${jobNums}</b>在招职位</a></span><em class="vline"></em><span><b>${companyManages}</b>位BOSS</span>
                <div class="op">
                    <a href="#" class="fl icon-resume" ka="job_online_resume_0"><i class="icon icon-resume"></i>填写在线简历 </a>
                    <a href="#" class="fr icon-upload" ka="job_attach_resume_0"><i class="icon"></i>上传附件简历</a>
                </div>
            </div>
            <div class="info-primary">
                <img src="${result.companyDetail.companyImg}"  class="fl">
                <div class="info">
                    <h1 class="name">${result.companyDetail.companyName}<i class="icon-brand"></i></h1>
                    <p>${result.companyDetail.companyFinance}<em class="dolt"></em>${result.companyDetail.companyScale}<em class="dolt"></em><a href="/i100020/" title="" class="industry-link">${result.companyDetail.companyIndustry}</a></p>
                </div>
            </div>
        </div>
        <!-- 下拉导航条开始 -->
        <div class="xiala">
            <div class="smallbanner notag">
                <div class="smallbanner-content">
                    <div class="company-stat">
                        <div class="op">
                            <a href="/web/user/resume-parse" class="fl icon-resume" ka="job_online_resume_0"><i class="icon icon-resume"></i>填写在线简历 </a>
                            <a href="/web/user/resume-parse" class="fr icon-upload" ka="job_attach_resume_0"><i class="icon"></i>上传附件简历</a>
                        </div>
                    </div>
                    <div class="info-primary">
                        <img src="${result.companyDetail.companyImg}" alt="" class="fl">
                        <div class="info">
                            <span class="name">${result.companyDetail.companyName}<i class="icon-brand"></i></span>
                        </div>
                    </div>
                    <div class="company-tab">
                        <a href="/gongsi/ab9fdc6f043679990HY~.html" ka="company-intro" class="cur">公司简介</a>
                        <a href="/gongsir/ab9fdc6f043679990HY~.html" ka="company-jobs" class="">招聘职位(${jobNums})</a>
                    </div>
                </div>
            </div>
        </div>

        <!-- 下拉导航条结束 -->
        <div class="company-tab company-tab2">
            <a href="javaScript:;" ka="company-intro" class="cur">公司简介</a>
            <a href="#" ka="company-jobs" class="">招聘职位(${jobNums})</a>
        </div>
    </div>
</div>
<div class="box1">
    <div class="company-hotjob">
        <div class="inner home-inner">
            <h3><a href="javaScript:;" class="more" ka="all-jobs-hot">查看全部${jobNums}个职位&nbsp;&nbsp;&nbsp;></a>热招职位</h3>
            <ul>
                <c:forEach items="${result.jobDetailList}" var="job" begin="0" end="2">
                    <li>
                        <a href="${pageContext.request.contextPath}/job/getById/${job.jobId}" target="_blank" ka="hot-job-1">
                            <div class="info-primary">
                                <div class="name"><span class="salary">${job.jobMinSalary}-${job.jobMaxSalary}</span><b>${job.jobName}</b></div>
                                <p class="gray">${job.jobExperience}·${job.jobDegree}·${job.jobLocCity}</p>
                            </div>
                        </a>
                    </li>
                </c:forEach>

            </ul>
        </div>
    </div>
    <div class="job-detail">
        <div class="content">
            <div class="job-content">
                <div class="job-sec">
                    <h3>${result.companyDetail.companyName}公司介绍</h3>
                    <p>公司简介</p>
                    <p class="text">
                        ${result.companyDetail.companyDetail}
                    </p>
                </div>
                <%--                <div class="company-products-new">--%>
                <%--                    <h3>产品介绍</h3>--%>
                <%--                    <ul>--%>
                <%--                        <li>--%>
                <%--                            <div class="figure">--%>
                <%--                                <img src="https://img.bosszhipin.com/beijin/upload/com/app/20200308/b747810ad7114fdfbabc2d497557ef2f0d1888c0867e3f579d1e49ef2712e52b.png?x-oss-process=image/resize,w_100,limit_0" alt="">--%>
                <%--                            </div>--%>
                <%--                            <div class="text">--%>
                <%--                                <div class="name">--%>
                <%--                                    <a href="javascript:;" ka="production-1" rel="nofollow">--%>
                <%--                                        百度APP--%>
                <%--                                    </a>--%>
                <%--                                </div>--%>
                <%--                                <p class="company-product-slogan">有事搜一搜，没事看一看</p>--%>
                <%--                            </div>--%>
                <%--                                <div class="company-product-intro">--%>
                <%--                                    搜索+资讯客户端，日活跃用户数近两亿--%>
                <%--                                    <a href="javascript:;" class="more-view" style="display: none;">展开</a>--%>
                <%--                                </div>--%>
                <%--                        </li>--%>
                <%--                        <li>--%>
                <%--                            <div class="figure">--%>
                <%--                                <img src="https://img.bosszhipin.com/beijin/upload/com/app/20200308/54d57f1be23860b9cc452f87f3648ef60d1888c0867e3f579d1e49ef2712e52b.png?x-oss-process=image/resize,w_100,limit_0" alt="">--%>
                <%--                            </div>--%>
                <%--                            <div class="text">--%>
                <%--                                <div class="name">--%>
                <%--                                    <a href="javascript:;" ka="production-1" rel="nofollow">--%>
                <%--                                        百度地图--%>
                <%--                                    </a>--%>
                <%--                                </div>--%>
                <%--                                <p class="company-product-slogan">科技让出行更简单</p>--%>
                <%--                            </div>--%>
                <%--                                <div class="company-product-intro">--%>
                <%--                                    搜索地点、查询线路、实时路况,您的出行指南、生活助手--%>
                <%--                                    <a href="javascript:;" class="more-view" style="display: none;">展开</a>--%>
                <%--                                </div>--%>
                <%--                        </li>--%>
                <%--                        <li>--%>
                <%--                            <div class="figure">--%>
                <%--                                <img src="https://img.bosszhipin.com/beijin/upload/com/app/20200308/f21029f0baf3b939abef77be5f4ff15c0d1888c0867e3f579d1e49ef2712e52b.png?x-oss-process=image/resize,w_100,limit_0" alt="">--%>
                <%--                            </div>--%>
                <%--                            <div class="text">--%>
                <%--                                <div class="name">--%>
                <%--                                    <a href="javascript:;" ka="production-1" rel="nofollow">--%>
                <%--                                        百度网盘--%>
                <%--                                    </a>--%>
                <%--                                </div>--%>
                <%--                                <p class="company-product-slogan">让美好永远陪伴</p>--%>
                <%--                            </div>--%>
                <%--                                <div class="company-product-intro">--%>
                <%--                                    提供文件备份、同步和分享服务。空间大、速度快、安全稳固,--%>
                <%--                                    <a href="javascript:;" class="more-view" style="display: none;">展开</a>--%>
                <%--                                </div>--%>
                <%--                        </li>--%>
                <%--                </ul>--%>
                <%--                </div>--%>
                <%--                <div class="company-business">--%>
                <%--                    <h3>工商信息</h3>--%>
                <%--                    <h4>百度在线网络技术（北京）有限公司</h4>--%>
                <%--                    <div class="business-detail" style="height: 46px;">--%>
                <%--                        <ul>--%>
                <%--                            <li><span class="t">法定代表人：</span>崔珊珊</li>--%>
                <%--                            <li><span class="t">注册资本：</span>4520万美元</li>--%>
                <%--                            <li><span class="t">成立日期：</span>2000-01-18</li>--%>
                <%--                        </ul>--%>
                <%--                </div>--%>
                <%--                </div>--%>
                <div class="job-location">
                    <h3>公司地址</h3>
                    <div class="location-item">
                        <img src="${pageContext.request.contextPath}/public/static/images/jia-map.png" alt="">
                    </div>
                </div>
                <div class="company-desc">
                    <h3>在招职位</h3>
                    <div class="job-list">
                        <ul>
                            <c:forEach items="${jobAndManages}" var="jobManage">
                                <li>
                                    <div data-lid="9iWqlqFK5kc.search.4" data-jid="fbb42447afe949d51XZ53d64EFM~" ka="comp_desc_joblist_1">
                                        <div class="job-primary">
                                            <div class="info-primary">
                                                <h3 class="name">
                                                    <div class="title-box">
                                                        <a href="${pageContext.request.contextPath}/job/getById/${jobManage.jobDetail.jobId}" target="_blank" class="job-title" title="${jobManage.jobDetail.jobName}" ka="comp_desc_joblist_1" data-lid="9iWqlqFK5kc.search.4">${jobManage.jobDetail.jobName}</a>
                                                        <span class="job-area">[${jobManage.jobDetail.jobLocProvince}]</span>
                                                        <span class="job-pub-time"></span>
                                                    </div>
                                                    <div class="info-detail" style="top: 0px;"></div>
                                                </h3>
                                                <p>
                                                    <span class="red">${jobManage.jobDetail.jobMinSalary}-${jobManage.jobDetail.jobMaxSalary}</span>
                                                        ${jobManage.jobDetail.jobExperience}<em class="vline"></em>${jobManage.jobDetail.jobDegree}
                                                </p>
                                            </div>
                                            <div class="info-publis">
                                                <span class="name">
                                                    <img src="${jobManage.companyManage.manageImg}">
                                                        ${jobManage.companyManage.manageName}<em class="vline"></em>${jobManage.companyManage.managePosition}
                                                </span>
                                            </div>
                                        </div>
                                    </div>
                                    <div class="startchat-box yc" id="startchat">
                                        <input type="hidden" value="${sessionScope.loginPerson.personName}" id="header_message">
                                        <a ka="job-1-chat" href="javascript:void(0)" data-url="/wapi/zpgeek/friend/add.json?securityId=COiozlkiODauX-H1fAdvYBlo_s7DMwp9qaHLjybCjxedi0_NJgEhCkvjWuQFJevYElBrHFivuopJq-XATx7T&amp;jobId=fbb42447afe949d51XZ53d64EFM~&amp;lid=9iWqlqFK5kc.search.4" redirect-url="/web/geek/chat?id=5ca08ef19357253d1Hx-2dq7ElU~&amp;lid=9iWqlqFK5kc.search.4" class="btn btn-startchat">立即沟通</a>
                                    </div>
                                </li>
                            </c:forEach>
                        </ul>
                    </div>
                </div>
            </div>
            <script>
                var lis = document.querySelector('.job-list').querySelectorAll('li');
                var info_publics = document.querySelectorAll('.info-publis');
                var startchat = document.querySelectorAll('.startchat-box');
                for(var i = 0; i < lis.length; i++){
                    lis[i].setAttribute('data-index',i);
                    lis[i].onmouseover = function(){
                        var index = this.getAttribute('data-index');
                        for(var i = 0; i < lis.length; i++){
                            info_publics[i].className = 'info-publis';
                            startchat[i].className = 'startchat-box yc'
                        }
                        info_publics[index].className = 'info-publis yc';
                        startchat[index].className = 'startchat-box zs'
                    }
                }
            </script>
            <div class="job-manager">
                <div class="sign-wrap"></div>
                <div class="manager-list">
                    <h3>高管介绍</h3>
                    <div class="manager-inner">
                        <ul>
                            <c:forEach items="${jobAndManages}" var="jobManage">
                                <li class="cur">
                                    <div class="info-user">
                                        <img src="${jobManage.companyManage.manageImg}" alt="">
                                        <p><span class="name">${jobManage.companyManage.manageName}</span><span class="job-title">${jobManage.companyManage.managePosition}</span></p>
                                    </div>
                                    <div class="text fold-text">${jobManage.companyManage.manageIntroduct}<a href="javascript:;" ka="senior-more-1" class="more-view" style="display: inline;"><i class="fz fz-slidedown"></i></a></div>
                                </li>
                            </c:forEach>
                        </ul>
                    </div>
                </div>
                <div class="picture-list">
                    <h3>公司环境</h3>
                    <div class="slider-main">
                        <div class="layui-carousel" id="test10">
                            <div carousel-item="">
                                <div><img src="https://unpkg.com/outeres/demo/carousel/720x360-1.jpg"></div>
                                <div><img src="https://unpkg.com/outeres/demo/carousel/720x360-2.jpg"></div>
                                <div><img src="https://unpkg.com/outeres/demo/carousel/720x360-3.jpg"></div>
                                <div><img src="https://unpkg.com/outeres/demo/carousel/720x360-4.jpg"></div>
                                <div><img src="https://unpkg.com/outeres/demo/carousel/720x360-5.jpg"></div>
                            </div>
                        </div>
                    </div>
                </div>
                <!-- 注意：项目正式环境请勿引用该地址 -->
                <script src="${pageContext.request.contextPath}/public/static/layui/layui.js"></script>
                <script>
                    layui.use(['carousel', 'form'], function(){
                        var carousel = layui.carousel
                            ,form = layui.form;
                        carousel.render({
                            elem: '#test10'
                            ,width: '363px'
                            ,height: '197px'
                            ,interval: 3000
                        });
                    });
                </script>
            </div>
        </div>
    </div>
</div>
<div class="box2">
    <strong style="display: block;height: 1000px">这里面啥都没有哦</strong>

</div>


<!--尾部-->
<div id ="footer">
    <div class="footer_i">
        <div class="footer_i_left">
            <p>
                <span>Copyright  2022 LinkedChat</span>
                <span>京ICP备14013441号-5</span>
                <span>京ICP证150923号</span>
                <span>京网文[2020]0399-066 号</span>
                <span>
                 <img src="https://static.zhipin.com/v2/web/geek/images/icon-badge-1.png">电子营业执照
              </span>
                <span>
                  <img src="https://static.zhipin.com/v2/web/geek/images/icon-beian.png"> 京公网安备11010502032801
              </span>
                <span>朝阳网警</span>
                <span>人力资源服务许可证</span>
                <span>网上有害信息举报专区</span>
                <span>朝阳区人社局监督电话</span>
            </p>
        </div>
        <div class="footer_i_right">
            <a href="#" class="icon_weibo"><span></span></a>
            <a href="#" class="icon-weixin"><span></span></a>
            <a href="#" class="icon-app"><span></span></a>
            <a href="#" class="icon-client-app">
                <img src="https://img.bosszhipin.com/static/file/2021/dppx09luaq1637052502211.png" class="icon_im">
                <span></span></a>
        </div>
    </div>
</div>
<script>
    var box1 = document.querySelector('.box1');
    var box2 = document.querySelector('.box2');
    var enterA = document.querySelector('.company-tab2').querySelectorAll('a');
    enterA[0].onclick = function(){
        enterA[0].className = 'cur';
        enterA[1].className = '';
        box1.style.display = 'block';
        box2.style.display = 'none';
    }
    enterA[1].onclick = function(){
        console.log(box1.className);
        console.log(box2.className);
        enterA[0].className = '';
        enterA[1].className = 'cur';
        box1.style.display = 'none';
        box2.style.display = 'block';
    }

    window.onscroll = function() {
        var smallbanner = document.querySelector('.smallbanner');
        var scrTop = (document.body.scrollTop || document.documentElement.scrollTop);
        if (scrTop >= 330) {
            // 显示
            smallbanner.style.height = '173px';
            smallbanner.style.transition = 'height .3s';
            smallbanner.style.visibility = 'visible';
        } else {
            // 隐藏
            smallbanner.style.visibility = 'hidden';
            smallbanner.style.transition = 'height 0s';
            smallbanner.style.height = '0px';

            smallbanner.style.display = 'block';
        }
    }


    $("#startchat").click(function (){
        var loginPersonName = $("#header_message").val();
        if(loginPersonName === ""){
            alert("你的消息用户名已下线，从新登录吧赶紧！")
            location.href = "${pageContext.request.contextPath}/public/Person/Login.jsp";
        }else {
            location.href = "${pageContext.request.contextPath}/static/chatMain.jsp";
        }
    })
</script>

</body>
</html>